using UnityEngine;

public class PlayerController : MonoBehaviour
{
    public  float     moveSpeed     = 5f;
    private Rigidbody rb;

    void Update()
    {
        float ws = Input.GetAxis("Vertical");                                          
        float ad = Input.GetAxis("Horizontal");                                          
        this.transform.Translate(Vector3.forward * ws * Time.deltaTime * moveSpeed, Space.World); //前后移动
        transform.Translate(Vector3.right        * ad * Time.deltaTime * moveSpeed, Space.World); //左右移动
    }

   

}